//http://www.tinymce.com/tryit/classic.php
var tinyMceConfig = {
    mode : "textareas",
    selector: "textarea.mce_editor",
    plugins: [
        "advlist autolink autosave link image lists charmap print preview hr anchor",
        "wordcount visualblocks visualchars code fullscreen media nonbreaking",
        "table contextmenu directionality emoticons template textcolor paste textcolor"
    ],

    toolbar1: "undo redo | formatselect | bold italic underline strikethrough | forecolor backcolor | insertfile image media | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent blockquote ",
    toolbar2: "removeformat | link unlink anchor | hr nonbreaking charmap emoticons | visualblocks code preview fullscreen | restoredraft | myvideo mytag myorder myordertext",

    //menubar: false,
    remove_script_host : true,
    toolbar_items_size: 'small',
    relative_urls : false,
    setup : function(ed) {
        ed.addButton('myvideo', {
            title : '[video]',
            image : '/files/editors/tinymce405/myicon/myvideo.png',
            onclick : function() {
                //ed.focus();
                ed.selection.setContent('[video]'+ed.selection.getContent()+'[/video]');
            }
        });
        ed.addButton('myorder', {
            title : '[order]',
            image : '/files/editors/tinymce405/myicon/myorder.png',
            onclick : function() {
                ed.selection.setContent('[order]'+ed.selection.getContent()+'[/order]');
            }
        });
        ed.addButton('myordertext', {
            title : '[ordertext]',
            image : '/files/editors/tinymce405/myicon/myordertext.png',
            onclick : function() {
                ed.selection.setContent('[ordertext]'+ed.selection.getContent()+'[/ordertext]');
            }
        });
        ed.addButton('mytag', {
            title : '[tag]',
            image : '/files/editors/tinymce405/myicon/mytag.png',
            onclick : function() {
                ed.selection.setContent('[tag]'+ed.selection.getContent()+'[/tag]');
            }
        });
    }
};